'use strict';

//也可以这样写: ...controller('mainCtrl',['$scope',function($scope){}]);
angular.module('app').controller('favoriteCtrl',['$scope','$http','$state',function($scope, $http, $state){
    $http.get('data/myFavorite.json').then(function(resp){
        $scope.list = resp.data;
    })
}]);